var defaults = {
	"title-bar": "true",     // remove title-bar
	"ad-bar": "false",       // don't remove adds
	"leave-warning": "true", // warn when leaving the page
  "focus":"true",          // give the applet the focus @ startup
};

function get_bool(key) {
	var val = get(key);
	if(val == "false")
		return false;
	else
		return true;
}

function get(key) {
	var val = localStorage[key];
	if(val == undefined)
		val = defaults[key];
	return val;
};

function put(key,val) {
	localStorage[key] = val;
};

function restore() {
	localStorage.clear();
};
